﻿<%@ Page Title="Cadastro" Language="C#" MasterPageFile="~/MasterPage.Master" AutoEventWireup="true"
    CodeBehind="FrmCadastro.aspx.cs" Inherits="Prj_PedidoFacil_Cliente.FrmCadastro" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <script type="text/javascript" language="javascript">
        function formatar_mascara(src, mascara) {
            var campo = src.value.length;
            var saida = mascara.substring(0, 1);
            var texto = mascara.substring(campo);
            if (texto.substring(0, 1) != saida) {
                src.value += texto.substring(0, 1);
            }
        }  
    </script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div class="row">
        <div class="col-md-4">
            <div class="box-body">
                <div class="form-group">
                    <asp:TextBox ID="txtNome" placeholder="Nome*" required pattern="[çÇùÙúÚôÔõÕòÒóÓìÌíÍêÊèÈéÉáÁàÀãÃâÂaA-zZ\s]+$"
                        title="Apenas Letras." class="form-control" runat="server"></asp:TextBox>
                </div>
                <div class="form-group">
                    <asp:RadioButtonList ID="rblSexo" runat="server" RepeatDirection="Horizontal">
                        <asp:ListItem Value="F">Feminino</asp:ListItem>
                        <asp:ListItem Value="M">Masculino</asp:ListItem>
                    </asp:RadioButtonList>
                </div>
                <div class="form-group">
                    <asp:TextBox ID="txtDtNasc" type="date" CssClass="form-control" runat="server" MaxLength="10"
                        required="" Width="160px" onkeypress="formatar_mascara(this, '##/##/####')"></asp:TextBox>
                </div>
                <div class="form-group">
                    <asp:TextBox ID="txtFone" placeholder="Telefone*" name="phone" pattern="[0-9]{4,6}-[0-9]{3,4}$"
                        required="" class="form-control" runat="server" MaxLength="9"></asp:TextBox>
                </div>
                <div class="form-group">
                    <asp:TextBox ID="txtCelular" placeholder="Celular*" name="phone" pattern="[0-9]{4,6}-[0-9]{3,4}$"
                        required="" class="form-control" runat="server" MaxLength="9"></asp:TextBox>
                </div>
                <div class="form-group">
                    <asp:TextBox ID="txtEmail" placeholder="Email" CssClass="form-control" required type="email"
                        runat="server" Height="30px" MaxLength="150"></asp:TextBox>
                </div>
                <div class="form-group">
                    <asp:TextBox ID="txtSenha" placeholder="Senha*" class="form-control" runat="server"></asp:TextBox>
                </div>
                <div class="form-group">
                    <asp:TextBox ID="txtConfirmar" placeholder="Confirmar Senha*" class="form-control"
                        runat="server"></asp:TextBox>
                </div>
                <div class="form-group">
                    <div class="input-group">
                        <asp:TextBox ID="txtCep" required placeholder="CEP*" title="Apenas números." class="form-control"
                            pattern="[0-9]+$" formnovalidate="formnovalidate" runat="server" MaxLength="8"></asp:TextBox>
                        <span class="input-group-btn">
                            <asp:Button ID="btnConsultarCEP" class="btn btn-default" formnovalidate="formnovalidate"
                                runat="server" Text="Ir" />
                        </span>
                    </div>
                </div>
                <div class="form-group">
                    <asp:TextBox ID="txtLogradouro" placeholder="Logradouro*" MaxLength="100" class="form-control"
                        runat="server"></asp:TextBox>
                </div>
                <div class="form-group">
                    <asp:TextBox ID="txtNumero" MaxLength="5" pattern="[0-9]+$" required="" title="Apenas números."
                        placeholder="Número*" class="form-control" runat="server"></asp:TextBox>
                </div>
                <div class="form-group">
                    <asp:TextBox ID="txtBairro" MaxLength="50" placeholder="Bairro*" class="form-control"
                        runat="server"></asp:TextBox>
                </div>
                <div class="form-group">
                    <asp:DropDownList ID="ddlUF" class="form-control" runat="server">
                        <asp:ListItem Value="AC">AC</asp:ListItem>
                        <asp:ListItem Value="AL">AL</asp:ListItem>
                        <asp:ListItem Value="AM">AM</asp:ListItem>
                        <asp:ListItem Value="AP">AP</asp:ListItem>
                        <asp:ListItem Value="BA">BA</asp:ListItem>
                        <asp:ListItem Value="CE">CE</asp:ListItem>
                        <asp:ListItem Value="DF">DF</asp:ListItem>
                        <asp:ListItem Value="ES">ES</asp:ListItem>
                        <asp:ListItem Value="GO">GO</asp:ListItem>
                        <asp:ListItem Value="MA">MA</asp:ListItem>
                        <asp:ListItem Value="MG">MG</asp:ListItem>
                        <asp:ListItem Value="MS">MS</asp:ListItem>
                        <asp:ListItem Value="MT">MT</asp:ListItem>
                        <asp:ListItem Value="PA">PA</asp:ListItem>
                        <asp:ListItem Value="PB">PB</asp:ListItem>
                        <asp:ListItem Value="PE">PE</asp:ListItem>
                        <asp:ListItem Value="PI">PI</asp:ListItem>
                        <asp:ListItem Value="PR">PR</asp:ListItem>
                        <asp:ListItem Value="RJ">RJ</asp:ListItem>
                        <asp:ListItem Value="RN">RN</asp:ListItem>
                        <asp:ListItem Value="RO">RO</asp:ListItem>
                        <asp:ListItem Value="RR">RR</asp:ListItem>
                        <asp:ListItem Value="RS">RS</asp:ListItem>
                        <asp:ListItem Value="SC">SC</asp:ListItem>
                        <asp:ListItem Selected="True" Value="SE">SE</asp:ListItem>
                        <asp:ListItem Value="SP">SP</asp:ListItem>
                        <asp:ListItem Value="TO">TO</asp:ListItem>
                    </asp:DropDownList>
                </div>
                <div class="form-group">
                    <asp:TextBox ID="txtCidade" placeholder="Cidade*" MaxLength="50" class="form-control"
                        runat="server"></asp:TextBox>
                </div>
                <div class="form-group">
                    <asp:TextBox ID="txtComplemento" placeholder="Complemento*" MaxLength="50" class="form-control"
                        runat="server"></asp:TextBox>
                </div>
                <div class="form-group">
                    <asp:TextBox ID="txtPontoReferencia" placeholder="Ponto de Referência*" MaxLength="50" class="form-control"
                        runat="server"></asp:TextBox>
                </div>
                <div class="form-group">
                    <asp:DropDownList ID="ddlTipoEndereco" class="form-control" runat="server">
                        <asp:ListItem Value="SC">CASA</asp:ListItem>
                        <asp:ListItem Value="SE">TRABALHO</asp:ListItem>
                    </asp:DropDownList>
                </div>
                <div class="form-group">
                    <asp:TextBox ID="txtFace" placeholder="Face*" MaxLength="50" class="form-control"
                        runat="server"></asp:TextBox>
                </div>
                <div class="form-group">
                    <asp:TextBox ID="txtCpf" placeholder="Cpf*" MaxLength="50" class="form-control"
                        runat="server"></asp:TextBox>
                </div>
            </div>
        </div>
    </div>
    <div class="row">
        <div class="col-md-4">
            <div class="box-footer">
                <asp:Button ID="btnSalvar" class="btn btn-primary center-block" runat="server" Text="Salvar"
                    OnClick="btnSalvar_Click" />
            </div>
        </div>
    </div>
</asp:Content>
